import { FormType, IMyFormProps } from '@/base-ui/base-form/type'
import { ActionDesc } from '@/global/constant'

const lexiconSearch: IMyFormProps = {
  desc: ActionDesc.LexiconSearch,
  layout: { span: 7 },
  formConfig: {
    name: 'wrap',
    size: 'middle',
    labelAlign: 'right',
    labelCol: { flex: '80px', offset: 2 },
    colon: false
  },
  itemsConfig: [
    {
      type: FormType.Input,
      prop: 'sensitiveWord', //必写的，唯一标识,因为name属性不一定全部都会有
      label: '敏感词',
      name: 'sensitiveWord',
      input: {
        size: 'small',
        placeholder: '请输入敏感词'
      }
    },
    {
      type: FormType.Select,
      prop: 'sensitiveWordType',
      label: '敏感词类型',
      name: 'sensitiveWordType',
      select: {
        baseProps: {
          placeholder: '请选择类型',
          size: 'small'
        },
        options: [
          { value: 0, content: '黑名单' },
          { value: 1, content: '白名单' }
        ]
      }
    }
  ]
}

export default lexiconSearch
